import axios from '../../utils/axios'

// 上一次直播信息
export const teachLiveLast = (params: { }, method?: string) => {
    return axios({
        url: '/teach/live/last',
        method: method || 'get',

        data: {
            ...params
        }
    })
}

// 创建直播间
export const teachLiveCreate = (params: { }, method?: string) => {
    return axios({
        url: '/teach/live/create',
        method: method || 'get',
        data: {
            ...params
        }
    })
}

// 上传临时秘钥
export const teachCommonStsToken = (params: { }, method?: string) => {
    return axios({
        url: '/teach/common/sts/token',
        method: method || 'get',
        data: {
            ...params
        }
    })
}

// 发送消息
export const teachMessageSend = (params: { }, method?: string) => {
    return axios({
        url: '/teach/message/send',
        method: method || 'get',
        data: {
            ...params
        }
    })
}

// 直播记录
export const teachLiveList = (params: { page: Number, title: string }, method?: string) => {
    return axios({
        url: '/teach/live/list',
        method: method || 'get',
        data: {
            ...params
        }
    })
}

// 获取正在直播直播间
export const teachLiveDoing = (params: {}, method?: string) => {
    return axios({
        url: '/teach/live/doing',
        method: method || 'get',
        data: {
            ...params
        }
    })
}

// 结束直播
export const teachLiveFinish = (params: {}, method?: string) => {
    return axios({
        url: '/teach/live/finish',
        method: method || 'get',
        data: {
            ...params
        }
    })
}

// 禁言用户发言
export const teachMessageMute = (params: {}, method?: string) => {
    return axios({
        url: '/teach/message/mute',
        method: method || 'get',
        data: {
            ...params
        }
    })
}

// 解除用户发言
export const teachMessageUnmute = (params: {}, method?: string) => {
    return axios({
        url: '/teach/meeage/unmute',
        method: method || 'get',
        data: {
            ...params
        }
    })
}

// 用户信息
export const teachLiveTeach = (params: {}, method?: string) => {
    return axios({
        url: '/teach/live/user',
        method: method || 'get',
        data: {
            ...params
        }
    })
}

// 开播秘钥
export const teachLiveSecret = (params: {}, method?: string) => {
    return axios({
        url: '/teach/live/secret',
        method: method || 'get',
        data: {
            ...params
        }
    })
}

// 创建公开课
export const teachLiveOpenLive = (params: {}, method?: string) => {
    return axios({
        url: '/teach/live/open/live',
        method: method || 'get',
        data: {
            ...params
        }
    })
}



export default {}